﻿using Dos.ORM;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Finance.Poco
{
    /// <summary>
    /// 实体类ViewSaleData 。(属性说明自动提取数据库字段的描述信息)
    /// </summary>
    [Serializable]
    public partial class ViewSaleData : Entity
    {
        public ViewSaleData() : base("v_sale_data") { }

        #region Model
        private int _Id;
        private int _UserId;
        private decimal _Amount;
        private DateTime? _CreateTime;
        private string _CreateUserName;
        private string _Remarks;
        private DateTime? _SaleDate;
        private string _UserName;
        private string _Email;
        /// <summary>
        /// 
        /// </summary>
        public int Id
        {
            get { return _Id; }
            set
            {
                this.OnPropertyValueChange(_.Id, _Id, value);
                this._Id = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public int UserId
        {
            get { return _UserId; }
            set
            {
                this.OnPropertyValueChange(_.UserId, _UserId, value);
                this._UserId = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public decimal Amount
        {
            get { return _Amount; }
            set
            {
                this.OnPropertyValueChange(_.Amount, _Amount, value);
                this._Amount = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public DateTime? CreateTime
        {
            get { return _CreateTime; }
            set
            {
                this.OnPropertyValueChange(_.CreateTime, _CreateTime, value);
                this._CreateTime = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public string CreateUserName
        {
            get { return _CreateUserName; }
            set
            {
                this.OnPropertyValueChange(_.CreateUserName, _CreateUserName, value);
                this._CreateUserName = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public string Remarks
        {
            get { return _Remarks; }
            set
            {
                this.OnPropertyValueChange(_.Remarks, _Remarks, value);
                this._Remarks = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public DateTime? SaleDate
        {
            get { return _SaleDate; }
            set
            {
                this.OnPropertyValueChange(_.SaleDate, _SaleDate, value);
                this._SaleDate = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public string UserName
        {
            get { return _UserName; }
            set
            {
                this.OnPropertyValueChange(_.UserName, _UserName, value);
                this._UserName = value;
            }
        }
        /// <summary>
        /// 
        /// </summary>
        public string Email
        {
            get { return _Email; }
            set
            {
                this.OnPropertyValueChange(_.Email, _Email, value);
                this._Email = value;
            }
        }
        #endregion

        #region Method
        /// <summary>
        /// 是否只读
        /// </summary>
        public override bool IsReadOnly()
        {
            return true;
        }
        /// <summary>
        /// 获取列信息
        /// </summary>
        public override Field[] GetFields()
        {
            return new Field[] {
				_.Id,
				_.UserId,
				_.Amount,
				_.CreateTime,
				_.CreateUserName,
				_.Remarks,
				_.SaleDate,
				_.UserName,
				_.Email};
        }
        /// <summary>
        /// 获取值信息
        /// </summary>
        public override object[] GetValues()
        {
            return new object[] {
				this._Id,
				this._UserId,
				this._Amount,
				this._CreateTime,
				this._CreateUserName,
				this._Remarks,
				this._SaleDate,
				this._UserName,
				this._Email};
        }
        #endregion

        #region _Field
        /// <summary>
        /// 字段信息
        /// </summary>
        public class _
        {
            /// <summary>
            /// * 
            /// </summary>
            public readonly static Field All = new Field("*", "v_sale_data");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field Id = new Field("Id", "v_sale_data", "Id");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field UserId = new Field("userId", "v_sale_data", "userId");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field Amount = new Field("amount", "v_sale_data", "amount");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field CreateTime = new Field("createTime", "v_sale_data", "createTime");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field CreateUserName = new Field("createUserName", "v_sale_data", "createUserName");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field Remarks = new Field("remarks", "v_sale_data", "remarks");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field SaleDate = new Field("saleDate", "v_sale_data", "saleDate");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field UserName = new Field("userName", "v_sale_data", "userName");
            /// <summary>
            /// 
            /// </summary>
            public readonly static Field Email = new Field("email", "v_sale_data", "email");
        }
        #endregion


    }

}
